Skip to content

Do not partially use text blocks - #273

Merged
timtebeek merged 5 commits into
mainfrom
do_not_partially_use_text_blocks
Aug 16, 2023
Merged

timtebeek merged 5 commits into
mainfrom
do_not_partially_use_text_blocks

Conversation

@timtebeek

@timtebeek timtebeek commented Aug 16, 2023 •

Copy link
Copy Markdown
Member

What's changed?

No longer, for the time being, concatenate text blocks unless they are fully composed of string literals.

What's your motivation?

Before we would end up with partial conversions when SQL statements for instance used variables in the concatenation, which resulted in less than ideal text blocks. While we wait for a proper fix in #261 this

Fixes #260

Have you considered any alternatives or workarounds?

A separate check seemed easier than squeezing this into flatAdditiveStringLiterals, especially if we revisit this with #261

Any additional context

@timtebeek timtebeek self-assigned this Aug 16, 2023
@timtebeek
timtebeek marked this pull request as ready for review August 16, 2023 17:49
@timtebeek timtebeek added the bug Something isn't working label Aug 16, 2023

@kunli2 kunli2 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense, LGTM. thanks Tim!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

Discussion/question: Is the default application of UseTextBlocks too 'opinionated' ?

2 participants